package com.zhdl.websocket.custom.server;

import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @Description:
 * @author: liu zhenming
 * @date: 2023/8/18 9:52
 */
@Slf4j
@RestController
@RequestMapping("/custom")
public class CustomTest {


    @GetMapping("/push/{clientId}")
    public String testPush(@PathVariable("clientId") String clientId) throws Exception {

        CustomWsServer.pushCustomMsg(clientId, "个性化推送测试");

        return "ok";
    }


}
